//======================================================================================
//  Notes:Use this command to anonymously check out the latest project source code:
//  Non-members may check out a read-only working copy anonymously over HTTP.
//  http://YHQCodingWsp.googlecode.com/svn/trunk/
//
//  Author:		Kevin Yang
//  Email:		Bigearrabbit@qq.com
//
//  DATE:		2013-4-16
//
//  File Name:	YHQDockWidgetCAATools.h
//
//  Notes:
//
//======================================================================================
#ifndef YHQDockWidgetCAATools_H
#define YHQDockWidgetCAATools_H

//local library
#include "YHQFolderCAAOperate.h"

//YHQCodingCore Library
#include "YHQDockWidget.h"

//QT include
#include <QDockWidget>
#include <QListWidget>
#include <QString>

/// <summary>Pre-declare</summary>
/// <remarks></remarks>
/// <author>Kevin Yang</author>
/// <date>2013-4-23</date>
namespace Ui {
class YHQDockWidgetCAATools;
}

/// <summary>YHQDockWidgetCAATools</summary>
/// <remarks></remarks>
/// <author>Kevin Yang</author>
/// <date>2013-4-23</date>
class YHQDockWidgetCAATools : public YHQDockWidget
{
    Q_OBJECT;
    
public:
    explicit YHQDockWidgetCAATools(QWidget *parent = 0);
    ~YHQDockWidgetCAATools();
    
public://Property

    /// <summary>List of ignore</summary>
    /// <remarks></remarks>
    /// <author>Kevin Yang</author>
    /// <date>2013-4-23</date>
    YHHPropertyDefineGetGetSet(ListOfIgnore,  QStringList);

    /// <summary>List of Delete</summary>
    /// <remarks></remarks>
    /// <author>Kevin Yang</author>
    /// <date>2013-4-23</date>
    YHHPropertyDefineGetGetSet(ListOfDelete,  QStringList);
private:


    /// <summary>ActionDeleteFolder</summary>
    /// <remarks></remarks>
    /// <author>Kevin Yang</author>
    /// <date>2013-4-23</date>
    bool DeleteFolderContents(const QString & iFolderPath,
                              const QStringList & iFolderDelete,
                              const QStringList & iFolderIgnore);

    /// <summary>InitialFolderList</summary>
    /// <remarks></remarks>
    /// <author>Kevin Yang</author>
    /// <date>2013-4-23</date>
    void InitialFolderList();

    /// <summary>InitialFolderList</summary>
    /// <remarks></remarks>
    /// <author>Kevin Yang</author>
    /// <date>2013-4-24</date>
    void InitialFolderList(QVector<YHQ::FileInforsRow> & iListOfFolders,
                           QListWidget *ipListWidget);

    /// <summary>Move selected items</summary>
    /// <remarks></remarks>
    /// <author>Kevin Yang</author>
    /// <date>2013-4-24</date>
    bool MoveSelectedItems(QListWidget * ipListWidgetSource,
                           QListWidget * ipListWidgetTaret);

    private
    slots:

    /// <summary>Action for DeleteCAAFolder clicked </summary>
    /// <remarks></remarks>
    /// <author>Kevin Yang</author>
    /// <date>2013-4-23</date>
    void on_pushButtonDeleteCAAFolder_clicked();

    void on_pushButtonDeleteObjects_clicked();

    void on_pushButtonMoveToRight_clicked();

    void on_pushButtonMoveToLeft_clicked();

    void on_pushButtonDeleteCAAExportFolder_clicked();

    void on_pushButtonDeleteSvn_clicked();

    void on_pushButtonDeleteToolsData_clicked();

    void on_pushButtonDeleteDebugAndRelease_clicked();

    /// <summary>UpdateListOfFolders</summary>
    /// <remarks></remarks>
    /// <author>Kevin Yang</author>
    /// <date>2013-4-23</date>
    void UpdateListOfFolders();

    void on_pushButtonSvnInitialAdd_clicked();

private:
    Ui::YHQDockWidgetCAATools       *   ui;// ui pointer
};

#endif // YHQDockWidgetCAATools_H
